

	Emu48 - A freeware HP48 Emulator for Windows 95 and NT


--- Bugfixes and Additions of Emu48 V1.0 ---

Thank Sebastien Carlier for his emulator and that he made the sources 
public. Special thanks to Jean-Yves Avenard and Cyrille de Brebisson 
for there suggestions, additions and fixes.

My first contact with this emulator (Shareware Win48) was in early 
1997. At this time I worked with Windows NT 4.0. The emulator was 
unuseable for me at this time. As well I had some problems with the 
latest version of Emu48 (Version 1.0). This was the beginning of the 
"Unofficial Service Packs".


	********************
	* OPERATING SYSTEM *
	********************

This version of Emu48 should work with all Win32 platforms. Several 
problems with Windows NT 4.0 and Win95b are fixed now.


	***********
	* DISPLAY *
	***********

The display emulation is now closer to the original. But there are 
several problems left, especially with the gray scale emulation.


	********************
	* KEYBOARD CHANGES *
	********************

I changed the behaviour for pressing more than one key. All keys will 
release, when you go outside the button area now. To hold down a key, 
you have to press the right mouse button. The key autorepeat emulation 
is working now.


	*********
	* CLOCK *
	*********

The emulator time is synchronized with the PC time at startup of the 
emulator. This may cause problems with other non original operating 
systems running on the HP48. On S(X) calculators the address area 
#00052-#00070, on G(X) calculators the address area #00058-#00076 in 
port0 are rewritten with the actual time information.


	***************
	* KML SCRIPTS *
	***************

Your LCD contrast setting will be saved now. In some cases you have to 
fix Color 0 in your KML script file, because the colors red and blue 
has been swapped in the "Lcd" section. Don't use TRUELCD.KMI for 
emulating display contrast in your scripts. It's not fully correct. 
The hardware contrast values are in the area from 0 to 31. But the 
HP48 roms bounds them to useful values. The S(X) rom use only display 
contrast values between 3 and 19 and the G(X) rom values between 9 and 
24. Now you can use 4 as value for "Zoom" in the "Lcd" section of the 
KML script for a very big display view.


	************************
	* REAL SPEED EMULATION *
	************************

As you recognized the speed of the emulated HP48 is much faster than 
an original HP48. The reason is, the the assembler commands are 
emulated faster than the original cpu can execute them. On one side 
this is a big advantage (faster execution of programs) on the other 
side this cause many trouble. In Emu48 only the timers works with the 
original speed. In result all commands like User-RPL WAIT wait more or 
less the correct time. But many programs like shells or editors use an 
own key handler to realize an autorepeat implementation. Normally 
these programs use the execution time of each assembler commands for 
waiting. On Emu48 this time is much shorter, so the time between each 
key read is shorter as well and you get a very fast key repetition. 
The editor ED from the JAZZ package hasn't this problem, because the 
key input is synchronized with one of the timers. To solve this 
problem Emu48 generally slow down emulation if a key is pressed. To 
solve some other speed depending problems you are able to slow down 
the whole emulation speed. There are two variables 'SXCycles=82' and 
'GXCycles=123' defined in the Emu48.ini file, section [Emulator] which 
control the "real" speed for each calcucator type. Each numeric value 
is standing for the allowed cpu cycles in a 16384Hz time frame. 
Because the used cycle statements (from SASM.DOC) in Emu48 doesn't 
correspond to the real values of the cpu, the saved values are 
estimated by comparing the execution time of a program to the real 
calculator. Increasing the value fitting to your ROM will make the 
"real speed" HP faster and vice versa. No warranty to the 
functionality of Emu48 when you go below the default values.


	*************************
	* SERIAL PORT EMULATION *
	*************************

The serial ports are emulated as well now. You may choose the same 
serial port for wire and IR. Remember that the IR port only work with 
2400 Baud. There's a problem known with the command RECX from the 
Library 1275: "XYMODEM v3.2 for S/G". On fast PC's this command 
doesn't work. Slow down emulation to run it. If you want to change the 
serial port settings, but they are disabled, close the serial port 
with the command CLOSEIO or power cycle the HP48 first.

Now it is possible to make transfers between the HP48 and Emu48. If 
you have problems with the connection please try the following. 
There's a simple way to check if your serial port is used by another 
program. First disable the serial settings in both Combox boxes and 
very important close the settings dialog. Reopen the settings dialog 
and choose the COM port in the wire combobox to the port the HP48 is 
connected with. When you open this combobox you only see valid 
(unused) serial ports. Don't use the IR combobox, it only works with 
2400 Baud. The next important thing are the serial settings of the 
HP48 and Emu48, they must be equal. If this doesn't work then mostly 
there's a hardware problem, check this with connecting the HP48 with 
a transfer program you like on the same serial port.


	****************
	* DISASSEMBLER *
	****************

With the internal disassembler you're able to disassemble the HP48 
address area. The disassembler always see the mapped memory address. 
If you configured the RAM on #00000 you will always see the RAM and 
not the ROM at this address.


	**************
	* DDE SERVER *
	**************

I implemented a DDE server in Emu48 to transmit data from and to the 
HP stack with DDE. You have the same restrictions like with the 
commands "Load object..." and "Save Object..", that a running program 
may corrupt memory. Take care to transmit data only after the 
acknowledge of the last transaction.

Technical data:

Servername:      Emu48
Topicname:       Stack
Item:            Dummy (ignored, must be a nozerolen string)
Clipboardformat: "CF_HPOBJ" (user defined)

The DDE commands CONNECT, POKE and REQUEST are supported.

The structure of the clipboardformat "CF_HPOBJ":

+--------+------------------------------------+
| 4 Byte |             HP object              |
+--------+------------------------------------+
    \        \
     \        +--- normal HP object
      +----------- length of object (LSB first)


	********
	* TIPS *
	********

I hope some of your Emu48 problems has been solved as well. If you use 
a patched rom version (i.e. to solve the auto off problem), try an 
unpatched one. For best emulation check the "Accurate Timer" box and 
use the default value of 62 for the "Timer 1 Period" in the Settings 
dialog.


Christoph Gieelink, cgiess@swol.de

http://privat.swol.de/ChristophGiesselink
